var app = new Vue({
	el: '#app',
	data:{
		//foodList:['葱','姜','蒜']
		foodList:[
			{
				name:'葱',
				price:'10',
				discount:'0.5',
			},
			{
				name:'姜',
				price:'15',
				discount:'0.9',
			},
			{
				name:'蒜',
				price:'20',

			},
		],

		url:'http://www.baidu.com',
		imgurl:'http://www.baidu.com/img/bd_logo1.png',
		name:'Yo.',
		sex:'male',
		sexs:['male'],
		article:'我是文本输入框里面的内容！！！哈哈哈哈！',
		from: '3',
		dest:'',
		role:'hr',
		math:81,
		physics:92,
		english:87,
	},

	methods: {
		onClick: function(){
			console.log('clicked')
		},
		onEnter: function(){
			console.log('mouse enter ')
		},
		onLeave: function(){
			console.log('mouse leave ')
		},
		onSubmit: function(){
			console.log('onSubmit ')
		},
		onKeyup:function(){
			console.log('key pressed ')
		}
	},
	computed:{
		sum: function () {
			return this.math + this.physics + this.english
		},
		average: function(){
			return Math.round((this.sum)/3)
		}
	}
})

